/**
 * 历史数据导航模块
 */
(function(window, angular, undefined){
	var module = angular.module('water.apps.voc.ReportData.avgStatistics.avgStatisticsNAV', []);
	
	module.controller('reportAverageStatisticsNAVController',function($state,$rootScope,$scope,$monitorDataService,$DataReportService,$dateUtil){

		$("#datatype input").bind("click",function(){
			var ui = $(this).attr("ui");
			$state.go(ui);
		});
		
		$scope.$on('$stateChangeSuccess',
	            function(event, toState, toParams, fromState, fromParams){
					$("#datatype input").removeAttr("checked");
					$("#datatype input[ui='"+toState.name+"']").attr("checked","checked");
			 	}
			 );
	});
}(window, angular));	